package com.xianyun.site.iblog.support;

import com.alibaba.cola.catchlog.CatchAndLog;
import com.alibaba.cola.dto.Response;
import com.xianyun.site.support.api.SupportServiceI;
import com.xianyun.site.support.dto.SmsSendCmd;
import com.xianyun.site.support.dto.SmtpSendCmd;
import com.xianyun.site.iblog.support.command.SmsSendCmdExo;
import com.xianyun.site.iblog.support.command.SmtpSendCmdExo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 支撑服务 服务层
 * @author mac_zyj
 */
@Service
@CatchAndLog
public class SupportServiceImpl implements SupportServiceI {

    @Autowired
    private SmtpSendCmdExo smtpSendCmdExo;

    @Autowired
    private SmsSendCmdExo smsSendCmdExo;

    @Override
    public Response sendCheckSmtp(SmtpSendCmd smtpSendCmd) {
        return smtpSendCmdExo.execute(smtpSendCmd);
    }

    @Override
    public Response sendCheckSms(SmsSendCmd smsSendCmd) {
        return smsSendCmdExo.execute(smsSendCmd);
    }

}
